<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>项目添加页面</title>
    <link rel="stylesheet" href="../../../yl/index.css" />
    <!-- 布局样式 -->
    <link rel="stylesheet" href="../../../yl/style.css" />
    <link rel="stylesheet" href="../../../style/wangeditor.css">
    <link rel="stylesheet" href="../../../yl/mobile.css" />
    <link rel="stylesheet" href="../../../yl/easyui.css" />
    <link rel="stylesheet" href="../../../yl/icon.css" />
</head>

<body>
    <!-- <div id="app"> -->
    <div class="easyui-navpanel" id="app" v-cloak>
        <header>
            <div class="m-toolbar">
                <div class="m-title">{{type=='1'?'查看':'审核'}}申报信息</div>
            </div>
        </header>
        <div class="easyui-navpanel panel-body panel-body-nobottom panel-body-noborder" style="height: 3000px"
            id="MainTable" ref="MainTable"
            :data-options="JSON.stringify({ 'TableName': 'project', 'form': 'dataForm' ,'primary_key':'Project_SerialNumber' })">
            <div class="yl-main">
                <div class="table_titel">
                    <div class="titel">项目信息</div>
                </div>
                <el-form :model="dataForm" ref="form" :inline-message="true" style="width: 100%">
                    <el-descriptions :column="1" size="large" border>
                        <el-descriptions-item>
                            <template #label>
                                <div class="cell-item">项目名称</div>
                            </template>
                            <el-form-item prop="Project_Name"
                                :rules="[{ required: true, message: '请输入项目名称', trigger: 'blur' }]">
                                <el-input disabled v-model="dataForm.Project_Name" class="borderless-input"
                                    placeholder="请输入项目名称" />
                            </el-form-item>
                        </el-descriptions-item>
                        <el-descriptions-item>
                            <template #label>
                                <div class="cell-item">项目类别</div>
                            </template>
                            <el-form-item prop="Project_Name"
                                :rules="[{ required: true, message: '请输入项目类别', trigger: 'change' }]">
                                <el-select disabled clearable v-model.trim="dataForm.Project_Category_SerialNumber"
                                    placeholder="请选择项目类别" filterable style="width: 100%">
                                    <el-option v-for="(item,index) in project_category" :key="index"
                                        :label="item.Project_Category"
                                        :value="item.Project_Category_SerialNumber"></el-option>
                                </el-select>
                            </el-form-item>
                        </el-descriptions-item>
                        <el-descriptions-item>
                            <template #label>
                                <div class="cell-item">项目总预算金额</div>
                            </template>
                            <el-form-item prop="Project_Budget"
                                :rules="[{ required: true, message: '请输入项目总预算金额', trigger: 'blur' }]">
                                <el-input disabled v-model="dataForm.Project_Budget" class="borderless-input"
                                    placeholder="请输入项目总预算金额" />
                            </el-form-item>
                        </el-descriptions-item>
                        <el-descriptions-item>
                            <template #label>
                                <div class="cell-item">项目描述</div>
                            </template>
                            <el-form-item prop="Project_Description">
                                <el-input disabled type="textarea" :autosize="{ minRows: 2}"
                                    v-model="dataForm.Project_Description" class="borderless-input"
                                    placeholder="请输入项目描述" />
                            </el-form-item>
                        </el-descriptions-item>
                        <el-descriptions-item>
                            <template #label>
                                <div class="cell-item">项目实施主体</div>
                            </template>
                            <el-form-item prop="Project_Description"
                                :rules="[{ required: true, message: '请选择项目实施主体', trigger: 'change' }]">
                                <yl-cascader disabled
                                    :props="{ value:'Government_Agencies_SerialNumber', label:'Agensies_Name' ,checkStrictly: true }"
                                    v-model="dataForm.Project_Implementation_Subject" placeholder="请选择项目实施主体"
                                    :options="government_agencies"></yl-cascader>
                            </el-form-item>
                        </el-descriptions-item>
                        <el-descriptions-item>
                            <template #label>
                                <div class="cell-item">开始日期</div>
                            </template>
                            <el-form-item prop="Start_Date"
                                :rules="[{ required: true, message: '请选择开始日期', trigger: 'change' }]">
                                <el-date-picker disabled v-model="dataForm.Start_Date" type="date" placeholder="请选择开始日期"
                                    class="borderless-input" format="YYYY-MM-DD" value-format="YYYY-MM-DD"
                                    size="large" />
                            </el-form-item>
                        </el-descriptions-item>
                        <el-descriptions-item>
                            <template #label>
                                <div class="cell-item">结束日期</div>
                            </template>
                            <el-form-item prop="End_Date"
                                :rules="[{ required: true, message: '请输入结束日期', trigger: 'change' }]">
                                <el-date-picker disabled v-model="dataForm.End_Date" type="date" placeholder="请选择结束日期"
                                    class="borderless-input" format="YYYY-MM-DD" value-format="YYYY-MM-DD"
                                    size="large" />
                            </el-form-item>
                        </el-descriptions-item>
                        <el-descriptions-item>
                            <template #label>
                                <div class="cell-item">相关自然资源</div>
                            </template>
                            <el-form-item prop="Natural_Resource_SerialNumber">
                                <yl-select v-model="Natural_Resource_SerialNumber" clearable disabled filterable
                                    placeholder="请选择自然资源" :options="natural_resources_management"
                                    :props="{value:'Natural_Resource_SerialNumber',label:'Natural_Resource_Name',multiple :true}">
                                    <el-table-column prop="Natural_Resource_SerialNumber" show-overflow-tooltip
                                        label="自然资源流水号"></el-table-column>
                                    <el-table-column prop="Natural_Resource_Name" show-overflow-tooltip
                                        label="自然资源名称"></el-table-column>
                                    <el-table-column prop="Area" label="自然资源面积"></el-table-column>
                                </yl-select>
                            </el-form-item>
                        </el-descriptions-item>
                        <el-descriptions-item>
                            <template #label>
                                <div class="cell-item">备注</div>
                            </template>
                            <el-form-item prop="Remarks">
                                <el-input disabled type="textarea" :autosize="{ minRows: 2}" v-model="dataForm.Remarks"
                                    class="borderless-input" placeholder="请输入备注" />
                            </el-form-item>
                        </el-descriptions-item>
                        <el-descriptions-item>
                            <template #label>
                                <div class="cell-item">紧急等级</div>
                            </template>
                            <el-form-item prop="Emergency_Sign"
                                :rules="[{ required: true, message: '请输入紧急等级', trigger: 'blur' }]">
                                <el-input disabled v-model="dataForm.Emergency_Sign"
                                    class="borderless-input"></el-input>
                            </el-form-item>
                        </el-descriptions-item>
                        <el-descriptions-item>
                            <template #label>
                                <div class="cell-item">项目负责人</div>
                            </template>
                            <el-form-item prop="Project_Captain_SerialNumber"
                                :rules="[{ required: true, message: '请选择项目负责人', trigger: 'change' }]">
                                <yl-select disabled v-model="dataForm.Project_Captain_SerialNumber" clearable filterable
                                    placeholder="请选择项目负责人" :options="government_member_information"
                                    :props="{value:'ID_Card_Number',label:'Personal_Name'}">
                                    <el-table-column prop="ID_Card_Number" show-overflow-tooltip
                                        label="身份证号"></el-table-column>
                                    <el-table-column prop="Personal_Name" show-overflow-tooltip
                                        label="姓名"></el-table-column>
                                    <el-table-column prop="Gender" show-overflow-tooltip label="性别"></el-table-column>
                                    <el-table-column prop="Home_Address" label="家庭住址"></el-table-column>
                                    <el-table-column prop="Contact_Phone" label="联系方式"></el-table-column>
                                </yl-select>
                            </el-form-item>
                        </el-descriptions-item>
                    </el-descriptions>
                </el-form>
                <div id="ChildTable">
                    <div class="table_titel">
                        <div class="titel">附件</div>
                    </div>
                    <el-table id="table" border max-height="450" tooltip-effect="dark" :data="childDataForm2">
                        <el-table-column min-width="180" prop="Attachment_SerialNumber" label="附件流水号"></el-table-column>
                        <el-table-column min-width="180" align="center" prop="Attachment_Type" label="附件类型">
                            <template v-slot="{row}">
                                <el-tag :type="row.Attachment_Type == '0'?'primary':'danger'">{{row.Attachment_Type ==
                                    '0'?'项目附件':'申报材料'}}</el-tag>
                            </template>
                        </el-table-column>
                        <el-table-column min-width="180" prop="Attachment_Name" label="附件名称"></el-table-column>
                        <el-table-column min-width="180" prop="Attachment_URL" label="磁盘文件名"></el-table-column>
                        <el-table-column width="200" fixed="right" align="center" label="操作">
                            <template v-slot="{row}">
                                <el-button type="primary" size="small" @click="preview(row)">
                                    在线预览
                                </el-button>
                                <el-button type="success" size="small" @click="download(row)">
                                    下载附件
                                </el-button>
                            </template>
                        </el-table-column>
                    </el-table>
                    <div class="table_titel">
                        <div class="titel">项目节点</div>
                    </div>
                    <el-form :model="{childDataForm:childDataForm.filter(item => item.Row_Status != '1')}" ref="form1"
                        :inline-message="true" style="width: 100%">
                        <el-descriptions :column="2" size="large" border style="margin-bottom: 10px;"
                            v-for="(item,index) in childDataForm.filter(item => item.Row_Status != '1')" :key="index"
                            :data-options="JSON.stringify({ 'TableName': 'project_node', 'form': 'childDataForm', 'ParentTableName': 'project'})">
                            <el-descriptions-item>
                                <template #label>
                                    <div class="cell-item">节点名称</div>
                                </template>
                                <el-form-item :prop="'childDataForm.'+index+'.Project_Node'"
                                    :rules="[{ required: true, message: '请输入节点名称', trigger: 'blur' }]">
                                    <el-input disabled v-model="item.Project_Node" class="borderless-input"
                                        placeholder="请输入节点名称" />
                                </el-form-item>
                            </el-descriptions-item>
                            <el-descriptions-item>
                                <template #label>
                                    <div class="cell-item">项目节点负责人</div>
                                </template>
                                <el-form-item :prop="'childDataForm.'+index+'.Project_Node_Captain_SerialNumber'"
                                    :rules="[{ required: true, message: '请选择项目节点负责人', trigger: 'change' }]">
                                    <yl-select disabled v-model="item.Project_Node_Captain_SerialNumber" clearable
                                        filterable placeholder="请选择项目节点负责人" :options="government_member_information"
                                        :props="{value:'ID_Card_Number',label:'Personal_Name'}">
                                        <el-table-column prop="ID_Card_Number" show-overflow-tooltip
                                            label="身份证号"></el-table-column>
                                        <el-table-column prop="Personal_Name" show-overflow-tooltip
                                            label="姓名"></el-table-column>
                                        <el-table-column prop="Gender" show-overflow-tooltip
                                            label="性别"></el-table-column>
                                        <el-table-column prop="Home_Address" label="家庭住址"></el-table-column>
                                        <el-table-column prop="Contact_Phone" label="联系方式"></el-table-column>
                                    </yl-select>
                                </el-form-item>
                            </el-descriptions-item>
                            <el-descriptions-item>
                                <template #label>
                                    <div class="cell-item">项目节点描述</div>
                                </template>
                                <el-form-item :prop="'childDataForm.'+index+'.Project_Node_Description'">
                                    <el-input disabled type="textarea" :autosize="{ minRows: 2}"
                                        v-model="item.Project_Node_Description" class="borderless-input"
                                        placeholder="请输入备注" />
                                </el-form-item>
                            </el-descriptions-item>
                            <el-descriptions-item>
                                <template #label>
                                    <div class="cell-item">备注</div>
                                </template>
                                <el-form-item :prop="'childDataForm.'+index+'.Project_Node_Remarks'">
                                    <el-input disabled type="textarea" :autosize="{ minRows: 2}"
                                        v-model="item.Project_Node_Remarks" class="borderless-input"
                                        placeholder="请输入备注" />
                                </el-form-item>
                            </el-descriptions-item>
                            <el-descriptions-item>
                                <template #label>
                                    <div class="cell-item">预计开始日期</div>
                                </template>
                                <el-form-item :prop="'childDataForm.'+index+'.Project_Node_Start_Date'"
                                    :rules="[{ required: true, message: '请选择开始日期', trigger: 'change' }]">
                                    <el-date-picker disabled v-model="item.Project_Node_Start_Date" type="date"
                                        placeholder="请选择开始日期" class="borderless-input" format="YYYY-MM-DD"
                                        value-format="YYYY-MM-DD" size="large" />
                                </el-form-item>
                            </el-descriptions-item>
                            <el-descriptions-item>
                                <template #label>
                                    <div class="cell-item">预计结束日期</div>
                                </template>
                                <el-form-item :prop="'childDataForm.'+index+'.Project_Node_End_Date'"
                                    :rules="[{ required: true, message: '请输入结束日期', trigger: 'change' }]">
                                    <el-date-picker disabled v-model="item.Project_Node_End_Date" type="date"
                                        placeholder="请选择结束日期" class="borderless-input" format="YYYY-MM-DD"
                                        value-format="YYYY-MM-DD" size="large" />
                                </el-form-item>
                            </el-descriptions-item>
                            <el-descriptions-item>
                                <template #label>
                                    <div class="cell-item">项目节点预算金额</div>
                                </template>
                                <el-form-item :prop="'childDataForm.'+index+'.Project_Node_Budget'"
                                    :rules="[{ required: true, message: '请输入项目节点预算金额', trigger: 'blur' }]">
                                    <el-input disabled v-model="item.Project_Node_Budget" class="borderless-input"
                                        placeholder="请输入项目节点预算金额" />
                                </el-form-item>
                            </el-descriptions-item>
                            <el-descriptions-item>
                                <template #label>
                                    <div class="cell-item">施工单位号</div>
                                </template>
                                <el-form-item :prop="'childDataForm.'+index+'.Construction_Company_SerialNumber'"
                                    :rules="[{ required: true, message: '请输入施工单位号', trigger: 'blur' }]">
                                    <el-input disabled v-model="item.Construction_Company_SerialNumber"
                                        class="borderless-input" placeholder="请输入施工单位号" />
                                </el-form-item>
                            </el-descriptions-item>
                            <el-descriptions-item>
                                <template #label>
                                    <div class="cell-item">施工单位名称</div>
                                </template>
                                <el-form-item :prop="'childDataForm.'+index+'.Construction_Company_Name'"
                                    :rules="[{ required: true, message: '请输入施工单位名称', trigger: 'blur' }]">
                                    <el-input disabled v-model="item.Construction_Company_Name" class="borderless-input"
                                        placeholder="请输入施工单位名称" />
                                </el-form-item>
                            </el-descriptions-item>
                            <el-descriptions-item>
                                <template #label>
                                    <div class="cell-item">施工单位联系人</div>
                                </template>
                                <el-form-item :prop="'childDataForm.'+index+'.Construction_Company_Contacts'"
                                    :rules="[{ required: true, message: '请输入施工单位联系人', trigger: 'blur' }]">
                                    <el-input disabled v-model="item.Construction_Company_Contacts"
                                        class="borderless-input" placeholder="请输入施工单位联系人" />
                                </el-form-item>
                            </el-descriptions-item>
                        </el-descriptions>
                    </el-form>
                    <el-descriptions
                        :data-options="JSON.stringify({ 'TableName': 'project_natural_resource', 'form': 'childDataForm1', 'ParentTableName': 'project'})"></el-descriptions>
                    <el-descriptions
                        :data-options="JSON.stringify({ 'TableName': 'project_attachment', 'form': 'childDataForm2', 'ParentTableName': 'project'})"></el-descriptions>
                    <div class="table_titel">
                        <div class="titel">资金来源</div>
                    </div>
                    <el-form :model="{childDataForm3:childDataForm3.filter(item => item.Row_Status != '1')}" ref="form2"
                        :inline-message="true" style="width: 100%">
                        <el-descriptions :column="2" size="large" border style="margin-bottom: 10px;"
                            v-for="(item,index) in childDataForm3.filter(item => item.Row_Status != '1')" :key="index"
                            :data-options="JSON.stringify({ 'TableName': 'project_funds_source', 'form': 'childDataForm3', 'ParentTableName': 'project'})">
                            <el-descriptions-item>
                                <template #label>
                                    <div class="cell-item">资金来源</div>
                                </template>
                                <el-form-item :prop="'childDataForm3.'+index+'.Funds_Source_SerialNumber'"
                                    :rules="[{ required: true, message: '请选择资金来源', trigger: 'blur' }]">
                                    <el-select disabled clearable v-model.trim="item.Funds_Source_SerialNumber"
                                        placeholder="请选择资金来源" filterable style="width: 100%">
                                        <el-option v-for="(item,index) in funds_source" :key="index"
                                            :label="item.Funds_Source" :value="item.Funds_Source_SerialNumber">
                                        </el-option>
                                    </el-select>
                                </el-form-item>
                            </el-descriptions-item>
                            <el-descriptions-item>
                                <template #label>
                                    <div class="cell-item">资金金额</div>
                                </template>
                                <el-form-item :prop="'childDataForm3.'+index+'.Amount'">
                                    <el-input disabled v-model="item.Amount" class="borderless-input" placeholder="请输入资金金额" />
                                </el-form-item>
                            </el-descriptions-item>
                        </el-descriptions>
                    </el-form>
                </div>
            </div>
        </div>
        <yl-online-preview :file-url="fileUrl" v-model="showDialog"></yl-online-preview>
        <footer class="botton-ann">
            <el-button @click="goBack">返回</el-button>
            <el-button v-if="type!='1'" type="success" plain @click="handleSubmit('2')" :loading="loading">审核通过</el-button>
            <el-button v-if="type!='1'" type="danger" plain @click="handleSubmit('3')" :loading="loading">拒绝</el-button>
        </footer>
    </div>
</body>
<script src="../../../utils/utils.js"></script>
<script src="../../../config/config.js"></script>
<script src="../../../utils/compressor.js"></script>
<script src="../../../utils/wangeditor.js"></script>
<script src="../../../utils/mixins.js"></script>
<script src="../../../yl/vue.js"></script>
<script src="../../../yl/index.js"></script>
<script src="../../../yl/zh-cn.mjs"></script>
<script src="../../../yl/index.iife.min.js"></script>
<script src="../../../yl/jquery.min.js"></script>
<script src="../../../utils/jquery.cookie.js"></script>
<script src="../../../yl/jquery.easyui.min.js"></script>
<script src="../../../yl/jquery.easyui.mobile.js"></script>
<script src="../../../yl/moment.min.js"></script>
<script src="../../../utils/xlsx.full.min.js"></script>
<script src="../../../utils/pdf.min.js"></script>
<script src="../../../api/request.js"></script>
<script src="./js/examine.js"></script>

</html>